<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="renderer" content="webkit">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
    <title>表单</title>
    <link rel="stylesheet" href="__PUBLIC__/layui/css/layui.css">
    <link rel="stylesheet" href="__PUBLIC__/static/css/style.css">
    <link rel="icon" href="__PUBLIC__/static/image/code.png">
</head>
<body class="body">
<div class="tab-top">


<div class="search">
  <form class="layui-form" action="">
        <div class="layui-input-inline">
        <select name="search" lay-verify="required" class="search-name" lay-search="">
          <option value="user" {$search=='user' ? 'selected=""' : ''}>用户名</option>
          <option value="ip" {$search=='ip' ? 'selected=""' : ''}>IP</option>
        </select>
      </div>
  <div class="layui-inline">
    <input class="layui-input layui-input-sm" name="val" placeholder="请输入用户名" id="search-elm" autocomplete="off" value="{$val}">
  </div>
  <button class="layui-btn site-demo-active layui-btn-sm search-btn" data-type="reload">搜索</button>
</form>
</div>
</div>

<div class="system-table-1" style="padding-top:10px;clear:both;">

<table class="layui-table" lay-filter="parse-table-demo" id="test33">
  <thead>
    <tr>
      <th lay-data="{field:'id', width:50, sort: true}">ID</th>
      <th lay-data="{field:'user', width:100}">用户</th>
      <th lay-data="{field:'title',align:'right', width:120}">操作</th>
      <th lay-data="{field:'oid', width:120}">id</th>
      <th lay-data="{field:'ip', width:120}">ip</th>
      <th lay-data="{field:'time', width:180}">时间</th>
      <th lay-data="{field:'sort', minwidth:60}">备注</th>
    </tr> 
  </thead>
  <tbody>
{foreach $list as $k=>$v} 
    <tr>
      <td>{$v.id}</td>
      <td>{$v->user->user_name}</td>      
      <td>{$v->menu->id == "1" ? $v.url : $v->menu->title}</td>
      <td>{$v.operation_id}</td>
      <td>{$v.ip}</td>
      <td>{$v.create_time}</td>
      <td>{$v.url}--{$v.text}</td>
    </tr>
{/foreach}
  </tbody>
</table>

</div>
<div class="list-page">{$page|raw}</div>
<!-- 通用-970*90 -->
<script src="__PUBLIC__/layui/layui.js" charset="utf-8"></script>
<script src="__ADMIN__/js/comm.js" charset="utf-8"></script>
<script type="text/javascript">
layui.use(['form', 'table'], function() {
    var $ = layui.jquery,
        form = layui.form,
        table = layui.table;
    // you code ...

    //监听单元格编辑

});
</script>
</body>
</html>